<template>
  <div class="app-container">
    <el-button
      class="addBut"
      type="primary"
      v-if="activeName === 'emailSet'"
      @click="handleAddEmail"
      >添加邮箱</el-button
    >
    <el-tabs class="tabs-container" v-model="activeName">
      <el-tab-pane label="基本设置" name="basicSet">
        <basicSet v-if="activeName === 'basicSet'" />
      </el-tab-pane>
      <el-tab-pane label="邮箱设置" name="emailSet">
        <emailSet v-if="activeName === 'emailSet'" />
      </el-tab-pane>
    </el-tabs>
  </div>
</template>
<script>
import basicSet from '@/views/setting/set/basicSet'
import emailSet from '@/views/setting/set/emailSet'
export default {
  name: 'BasicSetPage',
  components: { basicSet, emailSet },

  props: [],
  data() {
    return {
      activeName: 'basicSet'
    }
  },
  computed: {},
  watch: {},
  created() {},
  mounted() {},
  methods: {
    handleAddEmail() {
      this.$router.push({ path: '/setting/basic-set/add-email', query: { type: 'add' } })
    }
  }
}
</script>
<style lang="scss" scoped>
.tabs-container {
  background-color: #fff;
  padding: 10px;
}
.addBut {
  position: absolute;
  right: 30px;
  top: 30px;
  z-index: 99;
}
</style>
